home *** CD-ROM | disk | FTP | other *** search
- Path: inforamp.net!ts23-06
- From: crs0794@inforamp.net (Geoffrey Welsh)
- Newsgroups: comp.dcom.modems
- Subject: Re: COMnRxTRIGGER
- Date: 30 Mar 1996 23:21:29 GMT
- Organization: InfoRamp Inc., Toronto, Ontario (416) 363-9100
- Message-ID: <4jkflp$n8n@sam.inforamp.net>
- References: <315B7E5F.6DCC@mnsi.net>
- NNTP-Posting-Host: ts23-06.tor.istar.ca
- X-Newsreader: News Xpress Version 1.0 Beta #4
-
- In article <315B7E5F.6DCC@mnsi.net>, Alan Henderson <alanh@mnsi.net> wrote:
- >In Navas's 28800 Modem FAQ, it is suggested that the COMnRXTRIGGER
- >setting should be 8 by default with a Windows for Workgroups driver. I
- >tried 8 and then 4 and still got CRC errors when downloading. The errors
- >stopped when I reduced the value to 1. Navas writes, "You should not go
- >down to 1 unless you are really desperate." Well, I guess I am desperate.
- >What I would like to know is what tradeoffs occur when the value is 1,
- >rather than a higher number. Any help to understand this would be greatly
- >appreciated.
-
- UARTs with multibyte buffers have multiple advantages. One - the reason why
- most people buy 16550A UARTs - is that you can set the trigger level low so
- that the UART will not lose data if the CPU can't fetch each byte before the
- next arrives.
-
- Another very good reason is to reduce the amount of time that the CPU spends
- switching into and out of interrupt service mode. Servicing an interrupt
- means that the CPU must perform a lot of unproductive administrative work in
- order to stop what it's doing, note what that was, go do something else,
- remember where it was before, and resume. To impose all of that overhead for
- just one byte is a shame if your UART can hold up to 16; by setting the
- trigger to 14 you can reduce the time the CPU spends going into and out of
- interrupts to 1/14th of its previous level... leaving more time for the CPU to
- do what you're waiting for it to do.
-
- Unfortunately, in your case, even a trigger level of 4 is too high. That is
- to say, the CPU can't always read the data in the UART's buffer before twelve
- more bytes arrive (0.0125 seconds at 9600 bps, 0.0021 seconds at 57600 bps),
- so data is occasionally lost. It only takes on lost data byte to trash an
- entire [sub]packet).
-
- Yes, if you can afford it, increase the trigger level in order to reduce the
- overhead. However, eliminating overruns should have a higher priority.
- John's FAQ has other suggestions on eliminating overruns that might permit you
- to set a hgher trigger level; I would suggest disabling multi-sector IDE
- transfers (often labelled "block mode" in BIOS setup screens), turning off
- write-back cache, and reducing your serial port speed to the next higher
- setting from 20% over your carrier speed (e.g. 19200 for 14.4, 38400 for 28.8,
- and 57600 for 33.6).
-
- --
- Geoffrey Welsh, Developer, InSystems Technologies Inc.
- Temporary: crs0794@inforamp.net; At work: insystem@pathcom.com
- At home: geoff@zswamp.uucp or [xenitec.on.ca|m2xenix.psg.com]!zswamp!geoff
- Capitalism is a cold-hearted system which guards the interests of whoever's
- at the top, yet hypocritically claims that it offers everyone a fair shot.
- So is every other system ever put in place by man.
-
-